﻿/* ============================================================
   tx-rwd.css - 2026 最終穩定整合版 (2026-04-21 校正產出)
   核心原則：100% 恢復 2025 原始色彩與結構，嚴禁自動優化。
   ============================================================ */

/* --- [1] 2025 原始基因區：嚴禁變動 --- */

body { font-family: "Times New Roman", "標楷體"; font-size: 18px; background-image: url('-cache/TxBackG.gif'); }
p    { font-size: 18px; font-family: "Times New Roman", "標楷體"; }

h1 { font-size: clamp(18px, 2.5vw, 40px); color: #000080; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; font-stretch: condensed; }
h2 { font-size: clamp(18px, 2.25vw, 36px); color: #000099; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; }
h3 { font-size: clamp(18px, 2vw, 32px); color: #0000b3; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; }
h4 { font-size: clamp(18px, 1.75vw, 28px); color: #0000cc; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; }
h5 { font-size: clamp(18px, 1.5vw, 24px); color: #0000e6; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; }
h6 { font-size: clamp(18px, 1.25vw, 20px); color: #0000ff; font-weight: bold; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-bottom: 4px; margin-top: 0; }

table { margin-top:10px; margin-bottom:10px; }
th    { font-size: 20px; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; color: #202020; }

tr.double:nth-child(odd)  { background-color:#0000FF; }
tr.double:nth-child(even) { background-color:#FFFF00; }

.present { font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; margin-top: 0px; margin-bottom: 8px; margin-right: 2px; color: #202020; }
.hilite  { color: #800080; }
.normal  { font-size:18px; }
.twelve  { font-size:16px; }
.small   { font-size:14px; margin-top: 0; margin-bottom: 0; }

.author   { font-size: 26px; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; color: #800080; font-weight: bold; margin-top: 0; margin-bottom: 4px; margin-right:2px; }
.note     { font-size: 16px; font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; color: #000080; margin-top: 0; margin-bottom: 0px; margin-right:1px; }
.credit   { font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; font-size: 12px; margin-top: 0px; margin-bottom: 0px; }
.verse    { font-weight: bold; font-style:italic; color: #3300CC; margin-top: 0; margin-bottom: 4px; }
.verse-en { font-family: "Comic Sans MS"; font-style:italic; color: #3300CC; margin-top: 0; margin-bottom: 4px; }
.caption  { font-size: 16px; color: #000080; font-family: "Times New Roman", "標楷體"; margin-top: 0; margin-bottom: 0; }

.tb-0   { margin-top: 0; margin-bottom: 0; }
.tb     { margin-top: 6px; margin-bottom: 6px; }
.top    { margin-top: 6px; margin-bottom: 0; }
.bottom { margin-top: 0px; margin-bottom: 6px; }
.center { text-align:center; }
.left   { float: left; }
.right  { float: right; }
.space  { font-size: 10px; margin-top: 0; margin-bottom: 0; }
.devide { background-image: url('-cache/TxRule.gif'); font-size: 8px; }

.ming   { font-family: 新細明體; }
.kai    { font-family: "標楷體"; }
.Arial  { font-family: Arial; }
.narrow { font-family: "Arial Narrow"; }
.ABlack { font-family: Arial Black; }
.bold   { font-weight: bold; color: #666666; }
.black  { font-family:"Arial Narrow","Trebuchet MS","微軟正黑體"; }

/* --- 恢復 2025 原始色彩數值 --- */
.border0 { border: 0px; padding:2px; text-align:left; vertical-align : top; }
.border1 { border: 1px solid #FFCC66; padding:2px; text-align:left; vertical-align : top; }
.bordery { border: 4px solid #FFCC66; padding:2px; text-align:left; vertical-align : top; }
.borderb { border: 4px solid #00CCFF; padding:2px; text-align:left; vertical-align : top; }
.borderp { border: 4px solid #CC00FF; padding:2px; text-align:left; vertical-align : top; }
.backgreen  { background-color: #D9FFB3; }
.backpink   { background-color: #FFCCFF; }
.backyellow { background-color: #FFFF99; }

.boxb { border-style: ridge; border-width: 10px; border-color: #00ccff; }
.boxp { border-style: ridge; border-width: 10px; border-color: #cc00ff; }
.boxy { border-style: ridge; border-width: 10px; border-color: #ffcc00; }

.navi-text   { font-family: "Arial Narrow","Trebuchet MS","微軟正黑體"; font-size: 18px; font-weight: bold; text-align: center; }
.navi-text.s { font-family: "Arial Narrow","Trebuchet MS","微軟正黑體"; font-size: 14px; font-weight: bold; text-align: center; }

a:visited { color: #0080FF; }
a:hover   { color: #FF9900; }
a:active  { color: #800080; }
a.navi:link    { color:#FFFF00; text-decoration:none; }
a.navi:visited { color:#FFFFFF; text-decoration:none; }
a.navi:hover   { color:#D2FF78; text-decoration:none; }
a.navi:active  { color:#800080; text-decoration:none; }

ol, ul, li { font-family: "Times New Roman", "標楷體"; font-size: 20px; }

#banner {
  font-family: "Arial Narrow","Trebuchet MS","微軟正黑體";
  font-size: clamp(18px, 2.5vw, 40px); color: #FFFF00; font-weight: bold; 
  margin: 0; font-stretch: condensed; text-align: center;
}

/* --- [2] 2026 AI 增量區：僅限 RWD 與 定錨修正 --- */

:root {
  --brand-orange: #FF5722;
  scroll-padding-top: 90px;
  scroll-behavior: smooth;
}

/* 定錨修正 */
@keyframes flash-and-fade { 0% { background-color: #FFFF00; } 100% { background-color: transparent; } }
:target { animation: flash-and-fade 2s ease-out; border-left: 5px solid var(--brand-orange); }

/* 2026 跑馬燈元件 (獨立類別，不影響舊結構) */
.mq-container {
    --mq-w: var(--mq-width, 420px); width: 100%; max-width: var(--mq-w); height: 40px; 
    line-height: 40px; overflow: hidden; background-color: #FFFFCC; border: 2px solid #0000FF;
    position: relative; display: flex; white-space: nowrap;
}
.mq-content {
    display: inline-block; white-space: nowrap; padding-left: var(--mq-w);
    animation: mq-final-move var(--mq-speed, 25s) linear infinite; font-size: 14pt; color: #0000FF; text-decoration: none;
}
@keyframes mq-final-move { from { transform: translateX(0); } to { transform: translateX(-100%); } }

/* 2026 RWD 全球邏輯 (僅針對 #head 框架進行自適應，不改動內容 class) */
#head.w3-padding, #head .w3-center, #head .w3-container, #head article.w3-threequarter, #head .w3-display-container {
    padding-left: 0px !important; padding-right: 0px !important;
}
#head .w3-display-container img.w3-image { width: 100% !important; max-width: none !important; display: block; }

@media (min-width: 601px) {
    #head article.w3-threequarter { width: 73% !important; margin-right: 2% !important; float: left; }
    #head .w3-quarter { width: 25% !important; float: left; }
}

@media (max-width: 600px) {
    #head article.w3-threequarter, #head .w3-quarter { width: 100% !important; margin-right: 0px !important; padding: 0 12px !important; }
    #head article table, #head article div { float: none !important; width: 100% !important; max-width: 100% !important; margin: 15px 0 !important; display: block !important; }
    #head article img { max-width: 100% !important; height: auto !important; }
}